import Vue from 'vue'
import VueRouter from 'vue-router'

Vue.use(VueRouter)

const routes = [
  {
    path: '/',
    name: 'Main',
    component: () => import('../views/Main.vue'),
    children: [
      {
        path: 'home',
        alias: '',
        name: 'Home',
        component: () => import('../views/Home.vue')
      },
      {
        path: 'liveBroadcast',
        name: 'LiveBroadcast',
        component: () => import('../views/LiveBroadcast.vue')
      },
      {
        path: 'dynamic',
        name: 'Dynamic',
        component: () => import('../views/Dynamic.vue')
      },
      {
        path: 'my',
        name: 'My',
        component: () => import('../views/My.vue')
      },
      {
        path:'community',
        name:"Community",
        component: () => import('../views/Community.vue')
      },
      {
        path:'radar',
        name:"Radar",
        component: () => import('../views/Radar.vue')
      }
    ]
  },
  {
    path: '/recommendLIstDetail/:id/:url',
    name: 'RecommendLIstDetail',
    component: () => import('../views/RecommendLIstDetail.vue')
  },
  {
    path: '/searchPage',
    name: 'SearchPage',
    component: () => import('../views/SearchPage.vue')
  },
  {
    path: '/goSearchSongPage/:id',
    name: 'GoSearchSongPage',
    component: () => import('../views/GoSearchSongPage.vue')
  }
  ,
  {
    path: '/login',
    name: 'Login',
    component: () => import('../views/Login.vue')
  },
  {
    path: '/personDetail/:userId',
    name: 'PersonDetail',
    component: () => import('../views/PersonDetail.vue')
  },
  {
    path: '/gologin',
    name: 'GoLogin',
    component: () => import('../views/GoLogin.vue')
  },
  {
    path: '/followListDetail/:userId',
    name: 'FollowListDetail',
    component: () => import('../views/FollowListDetail.vue')
  },
  {
    path: '/like',
    name: 'Like',
    component: () => import('../views/Like.vue')
  },
  {
    path: '/singerDetail',
    name: 'SingerDetail',
    component: () => import('../views/SingerDetail.vue')
  }
]

const router = new VueRouter({
  routes
})

export default router
